node-editor: Redo saving location
authorMatthias Clasen <mclasen@redhat.com>
Tue, 6 Dec 2022 11:13:59 +0000 (11:13 +0000)
committerMatthias Clasen <mclasen@redhat.com>
Fri, 9 Dec 2022 14:35:32 +0000 (09:35 -0500)
commit96b9ac84f8750449f5fbd9115830bc0b19394992
tree1eadbe26e87dbe7166c2756e30d9dfa9e9d676c5
parent860c2f8ddd102c814817f6ea1661fb483d82f286
node-editor: Redo saving location

Determine the location to save testcases in dynamically,
trying first a GTK_SOURCE_DIR environment variable
and then the current directory as the GTK source dir,
ultimatively falling back to just saving in the current
directory.

This avoids leaking details of the build environment
into the produced artifacts and should make GTK builds
more reproducible.

Fixes: #5403
demos/node-editor/meson.build
demos/node-editor/node-editor-window.c